<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        let geo={
            lat:'28.682',
            lng:'115.8579'
        };
        // 字符串得方式 ['28.682','115.8579'] 
        localStorage.setItem('geo',JSON.stringify(geo));// JSON.stringify 对象转换为JSON对象
        console.log(JSON.parse(localStorage.getItem('geo')));
        // localStorage.setItem('ls_name','菠萝头');// 一直在 5M
        // sessionStorage.setItem('ss_name','吸氧羊');// 会话中在，关闭了浏览器窗口
        // 没有性能问题
    </script>
</body>
</html>